<template>
  <div class="about">
    <PDFViewer :source="pdfSrc">
      <template #errorPage>
        <Result title="合同预览异常，请刷新页面重试，如仍异常请联系技术人员">
          <template #extra>
            <Button type="primary">点击刷新</Button>
          </template>
        </Result>
      </template>
    </PDFViewer>
  </div>
</template>

<script lang="ts" setup>
import { ref } from 'vue';
import { Result, Button } from 'ant-design-vue';
import { PDFViewer } from '@/components/Viewer';

const pdfSrc = ref(
  'https://saas-test-oss.tynd.com/match/admin/pdf/20240815105606007c6859.pdf?Expires=1723692035&OSSAccessKeyId=LTAI5tFzSgkcjQoBsL8XCi13&Signature=GV14u2qrmB0olZPDphjf0kZdNBs%3D'
);
</script>

<style>
.about {
  width: 500px !important;
  height: 300px !important;
}
</style>
